package com.nn.service.run;

import com.nn.service.api.DomainUtils;
import jakarta.annotation.Resource;
import org.slf4j.ILoggerFactory;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.mail.javamail.JavaMailSender;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.util.logging.Logger;

/**
 * @author niann
 * @description
 * @date 2024/1/5 15:07
 */

@EnableScheduling
@Component
public class Start {


    @Resource
    private DomainUtils utils;

    @Scheduled(fixedRate = 1000*60*2 )
    public void myScheduledTask() {
        utils.ipChange();
    }
}
